package com.lin.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.lin.entity.Money;
import org.apache.ibatis.annotations.Select;
import java.util.List;
import java.util.Map;
public interface MoneyMapper extends BaseMapper<Money>{
    @Select("SELECT AVG(total_time) AS avg FROM money")
    Double selectAverageTime();

    @Select("SELECT order_id AS orderId, total_time AS totalTime FROM money ORDER BY create_time")
    List<Map<String, Object>> selectOrderTimes();
}
